﻿using SheBao.BLL;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using SheBao.Model;
using SheBao.DALFactory;

namespace SheBao.UI.MVC.Controllers
{
    public class HomeController : Controller
    {
        //
        // GET: /Home/

        public ActionResult Index()
        {
            //UserDal u = new UserDal();
            //ViewData["List"] = u.GetList();
            UserService us = new UserService();
            us.Add(new Model.User()
            {
                LoginName = "1",
                Password = "1",
                Enable = true,
                CreateDate = DateTime.Now,
                LastLoginDate = DateTime.Now
            });
            DbSession dbSession = DbSessionFactory.GetCurrentDbSession();
            dbSession.SaveChanges();
            //SheBao.Model.User user = new User()
            //{

            //};
            return View();
        }

    }
}
